﻿using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;

using Tong;
public partial class aspnet_testPargrameDir_site_AboutUs : System.Web.UI.Page
{
    public string str = "";



    /// <summary>
    /// 用於顯示資料
    /// </summary>
    public Tong.TongUse TextData = new Tong.TongUse();

    /// <summary>
    /// 系统安装绝对路径
    /// </summary>
    public string Abs_Path = TongUse.SysPath;
    /// <summary>
    /// 用户存放数据的临时表
    /// </summary>
    DataTable MyDt = new DataTable();


    /// <summary>
    /// 站点通用方法类
    /// </summary>
    public Tong.ThisSiteUse.SiteTong TextThisSite = new Tong.ThisSiteUse.SiteTong();

    /// <summary>
    /// 當前顯示的id
    /// </summary>
    string id = "1";
    //得到传入的栏目ID
    public String CloumnID = "78";

    /// <summary>
    /// 欄目目錄
    /// </summary>
    public string CX_Column_Directory = "";

    /// <summary>
    /// 顯示當前欄目的簡介
    /// </summary>
    public string str1 = "";
    /// <summary>
    /// 資料表
    /// </summary>
    DataTable NewDt = new DataTable();

    /// <summary>
    /// 標題
    /// </summary>
    public string title = "";
    public string tab = "071cff89-cc4a-4086-9ec3-893e05f9b081";




    /// <summary>
    /// 类型名
    /// </summary>
    public string className = "layout-banner-a";

    protected void Page_Load(object sender, EventArgs e)
    {
        MyDt = TextData.SqlataSet("select * from [" + tab + "]  order by  [" + tab + "_Sort] desc").Tables[0];

        str = MyDt.Rows[0]["" + tab + "_Contont"].ToString();

        BindData();



    }

    /// <summary>
    ///邦定當前頁面的資料
    /// </summary>
    void BindData()
    {
        try
        {
            try
            {

                
                CloumnID = Request.QueryString["SendentID"].Trim();
            }
            catch
            {
                try
                {
                    CloumnID = Request.QueryString["CloumnID"].Trim();
                }
                catch { }
            }

            if (CloumnID == "1")
            {
                CloumnID = "74";
            }

            //關於我們子欄目管理
            tab = TextThisSite.SigeGetColumnTable(CloumnID);
            



            string id = Request["id"].ToString();
            NewDt = TextData.SqlataSet("select * from [" + tab + "] where [" + tab + "_id]=" + id).Tables[0];
            str = NewDt.Rows[0]["" + tab + "_Contont"].ToString();

            title = NewDt.Rows[0]["" + tab + "_Name"].ToString();


            //得到栏目图片信息
            DataTable mydt = TextData.SqlataSet("select * from [CX_Column] where CX_Column_id =" + CloumnID).Tables[0];
           if (mydt.Rows.Count > 0)
           { 
             className=mydt.Rows[0]["CX_Column_Pic"].ToString();
             str1 = mydt.Rows[0]["CX_Column_Name"].ToString();
           }


        }
        catch
        {

            CloumnID = "74";//联系我们

        }




    }





}



